package com.knowledge.review.designPatterns.creatormode.factorypattern.factorymethodpattern;

/**
 * 产品角色一
 * @author xufw
 */
public class Apple implements Fruit {
    @Override
    public String getColor() {
        return "红色";
    }
 
    @Override
    public String getTaste() {
        return "好吃";
    }
}

/**
 * 产品角色二
 */
class Pear implements Fruit {
    @Override
    public String getColor() {
        return "黄色";
    }
 
    @Override
    public String getTaste() {
        return "吃了还想吃";
    }
}

/**
 * 产品角色三
 */
class Orange implements Fruit {
    @Override
    public String getColor() {
        return "橙色";
    }
 
    @Override
    public String getTaste() {
        return "美味";
    }
}